<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%@ include file="../cabecalho.jsp"%>
<script type="text/javascript" src="<c:url value='/'/>/js/gdl.js"></script>
<script language="javascript" type="text/javascript"
	src="<c:url value='/'/>/js/interface.js"></script>
<script language="javascript" type="text/javascript"
	src="<c:url value='/'/>/js/jquery-ui.js"></script>
<script language="javascript" type="text/javascript"
	src="<c:url value='/'/>/js/dateFormat.js"></script>
<link href="<c:url value='/css/jquery-ui.css'/>" rel="stylesheet"
	type="text/css" />
<script type="text/javascript">
	jQuery(function($) {
		$("input.data").mask("99/99/9999", {
			placeholder : ""
		});
	});

	jQuery(function() {
		$(".column").sortable({
			connectWith : '.column',
			handle : $(".portlet-header")
		});

		$(".portlet").addClass(
				"ui-widget ui-widget-content ui-helper-clearfix ui-corner-all")
				.find(".portlet-header").addClass(
						"ui-widget-header ui-corner-all").prepend(
						'<span class="ui-icon ui-icon-minusthick"></span>')
				.end().find(".portlet-content");

		$(".portlet-header .ui-icon").click(
				function() {
					$(this).toggleClass("ui-icon-minusthick").toggleClass(
							"ui-icon-plusthick");
					$(this).parents(".portlet:first").find(".tabelaDiv")
							.toggle();
				});

	});
</script>

<%-- !-- Processo seletivo--%>
<div id="formProcessoSeletivo" class="form_cadastro">
	<div class="column" style="width: 100%">
		<div class="portlet">
			<div class="portlet-header">
				<fmt:message key="menu_processos_seletivos_vigentes" />
			</div>

			<div class="tabelaDiv maior">
				<table class="tabela" cellpadding="5px" cellspacing="0"
					id="tableFormacao">

					<tr>
						<th><b><fmt:message key="processo_seletivo_descricao_TITLE" />
						</b>
						</th>
						<th><b><fmt:message key="processo_seletivo_tipo_TITLE" /> </b>
						</th>
						<th><b><fmt:message
									key="cadastro_curriculo_tabela_titulo_data_ingresso" /> </b>
						</th>
						<th><b><fmt:message
									key="cadastro_curriculo_tabela_titulo_data_termino" /> </b>
						</th>
					</tr>
					<c:forEach var="processoSeletivo"
						items="${processosSeletivosVigentes}" varStatus="rowCounter">
						<c:choose>
							<c:when test="${rowCounter.count % 2 == 0}">
								<c:set var="rowStyle" scope="page" value="odd" />
							</c:when>
							<c:otherwise>
								<c:set var="rowStyle" scope="page" value="even" />
							</c:otherwise>
						</c:choose>


						<tr class="${rowStyle}">
							<td>${processoSeletivo.descricao}</td>
							<td>${processoSeletivo.tipoProcessoSeletivo}</td>
							<td><fmt:formatDate
									value="${processoSeletivo.dataDeAbertura}" pattern="dd/MM/yyyy" />
							</td>
							<td><fmt:formatDate
									value="${processoSeletivo.dataLimiteDeInscricao}"
									pattern="dd/MM/yyyy" />
							</td>
							<td><a
								href="<c:url value='/processoSeletivo/editar/${processoSeletivo.processoSeletivoId}'/>">
									<img src="<c:url value='/images/editar.png'/>"
									alt='<fmt:message key="editar"/>'
									title="<fmt:message key="editar"/>" /> </a>
							<td>
							<td><a
								href="<c:url value='/processoSeletivo/remover/${processoSeletivo.processoSeletivoId}'/>">
									<img src="<c:url value='/images/excluir.gif'/>"
									alt='<fmt:message key="excluir"/>'
									title="<fmt:message key="excluir"/>" 
									onclick="return confirm('<fmt:message
										key="tem_certeza_excluir" />');"/> </a>
							<td>
						</tr>
					</c:forEach>
				</table>
			</div>
		</div>
	</div>
	<div class="clear"></div>
</div>


<%@ include file="../rodape.jsp"%>